'.\" t
.TH "clhalt" "1M" "Jun 26, 2006" "1\&.2\&.0"
.SH NAME
clhalt \- Linuxha.net Cluster Shutdown tool

.SH SYNOPSIS
.TS
l.
clhalt [\fB--force\fP] [\fB--config\fP \fIfile\fP] [\fB--nochecksums\fP]
       Complete Cluster shutdown

clhalt \fB--node\fP \fIX\fP [\fB--action\fP \fIerror|halt|failover\fP] [\fB--nochecksums\fP]
       Shutdown a particular node

clhalt \fB-?\fP
       Show brief usage information
.TE

.SH DESCRIPTION
This utility is designed to shutdown either the complete cluster or
just one of the nodes running in the cluster. By default it will attempt
to shutdown the cluster - though only if no applications are currently running. This behaviour can be overridden using the \fB--force\fP argument.

The \fIclhalt(1M)\fP command can be run on either node in the cluster 
and works whether either or both nodes are currently part of the cluster.

Alternatively it is possible to shutdown just a single node in the
cluster making use of the \fB--node\fB option. When shutting down a single
node the administrator can force the command to work in different
ways if the node in question is currently running any applications.

.SH ARGUMENTS
.TP 4
.B --force
If this argument is present and any applications are currently running then
it will call \fIclhaltapp(1M)\fP for each application in turn prior to
halting the cluster. This argument is only relevant when shutting down the
complete cluster - see the \fB--action\fP option if shutting down just
a single node.

Only use this flag if you are sure that no access to clustered applications 
is still needed - otherwise such sessions will be lost.
.TP
.B --nochecksums
Normally if the cluster or application configuration file 
have been modified whilst the cluster is running the
checksums which are used to indicate the last sane and checked configuration 
will not be valid. In such instances many of the Linuxha.net commands, including
this one will not will not function. If necessary the \fB--nochecksums\fP 
option can be used to overcome this until the cluster or application 
configuration are next rebuilt using the \fIclbuild(1M)\fP or 
\fIclbuildapp(1M)\fP utilities.
.TP
.B --node
Used to indicate a particular node that is to leave the cluster. If this
node is not currently in an 'UP' state an error will be given. If any
applications are currently running on this node, the steps taken are
determined by the \fB--action\fP setting, which defaults to "error".
.TP
.B --action
Determines the action to take when shutting down a single node. If not
specified it will default to the "error" action. The following actions
are supported:

.RS 4
.TP 8
* error
Do not halt the node - all currently running applications on this node
remain running.
.TP
* halt
All currently running applications are stopped prior to halting the node.
.TP
* failover
All currently running applications are failed-over to the alternative node
if possible prior to halting the cluster services on this node.

.SH TIME DEPENDENCIES
Unlike forming a cluster there are no time dependencies for 
halting the cluster. However given that the shutdown of any applications,
(if the \fB--force\fP flag is used), writes out the time of last use of
each stopped application, large inaccuracies (a minute or more), might
result in incorrect data validation decisions when the application is 
restarted.

.SH EXIT STATUS
The \fIclhalt(1M)\fP utility makes use of many error codes, but in summary
it will return a non-zero number for an error or zero if the information
requested has been successfully processed.

.SH SEE ALSO
.TS
l l.
clbuild(1M)	- Build / Validate cluster topology
clbuildapp(1M)	- Build / Synchronise cluster application 
cldeamon(1M)	- Cluster status Daemon
cldaemonctl(1M)	- Send control messages to Daemon
clform(1M)	- Form a cluster
clrunapp(1M)	- High level tool to start clustered application
clstartapp(1M)	- Start a clustered application
clhaltapp(1M)	- Halt a clustered application
clstat(1M)	- Show cluster status information
clconf.xml(5)	- Overall cluster topology configuration file
appconf.xml(5)	- Configuration of an application used by the cluster
.TE

.SH AUTHOR
The \fIclhalt(1M)\fP utility was written by Simon Edwards, 2003-2006. The
author can be contacted via the website mentioned below.

.SH AVAILABILITY
This software is freely available from the Linuxha.net website - please see
\fBhttp://www.linuxha.net\fP for more details.

.SH WARRANTY
This is Open Source Software is per the GNU GPL. It is free to use and
distribute but \fIcomes with no warranty whatsoever\fP. For more information
on the license please see \fBwww.gnu.org/copyleft/gpl.html\fP.

